/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package regras;

import Interfaces.CheckerRule;

/**
 *
 * @author Tainá, Ana Luiza e Amanda
 */
public class RuleLetters01 implements CheckerRule{
    public String password;

    public RuleLetters01(String password) {
        this.password = password;
    }
    
    @Override
    public int rule(){
        int total = 0;
        String senha = " "+password+" ";
        if (senha.split("([A-Z])").length - 1>0 && senha.split("([a-z])").length - 1>0)
            total += 2;
        
        return total;
    }
}
